Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

exenv-es6

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

exenv-es6

React's ExecutionEnvironment module recreated as ES6 functions

  • 1.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
78K
decreased by-23.2%
Maintainers
1
Weekly downloads
 
Created
Source

exenv-es6

React's ExecutionEnvironment module extracted as ES6 functions. Based on the ExecutionEnviroment module licensed under the MIT license by Facebook, Inc

Package exports

canUseDOM - Checks if the DOM is available to access and use canUseWorkers - Checks if Web Workers are available for use canUseEventListeners - Checks if Event Listeners are available for use canUseViewport - Checks if there is a viewport available

Usage

npm i exenv-es6 --save
import { canUseDOM } from "exenv-es6";

if (canUseDOM()) {
    // do something that requires the dom
}

Inspired by exenv from JedWatson

Keywords

FAQs

Package last updated on 31 Mar 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc